﻿namespace Arms.Presentation.Web.Areas.Reports.Controllers
{
    using Arms.Application.Modules.Reports;
    using Arms.Presentation.Web.Controllers;
    using System.Web.Mvc;

    public class QuickReportController : BaseController
    {
        private readonly IQuickReportService _service;
        public QuickReportController(IQuickReportService service)
        {
            _service = service;
        }

        /// <summary>
        /// Gets the average daily income.
        /// </summary>
        /// <returns></returns>
        public ActionResult GetAverageDailyIncome()
        {
            return Json(_service.GetAverageDailyIncome(), JsonRequestBehavior.AllowGet);
        }
        /// <summary>
        /// Gets the number of orders made today .
        /// </summary>
        /// <returns></returns>
        public ActionResult GetDailyOrderCount()
        {
            return Json(_service.GetDailyOrderCount(), JsonRequestBehavior.AllowGet);
        }
        /// <summary>
        /// Gets the income made today.
        /// </summary>
        /// <returns></returns>
        public ActionResult GetDailyIncome()
        {
            return Json(_service.GetDailyIncome(), JsonRequestBehavior.AllowGet);
        }
        /// <summary>
        /// Gets the quick report dto.
        /// </summary>
        /// <returns></returns>
        public ActionResult GetQuickReport()
        {
            return Json(_service.GetQuickReport(), JsonRequestBehavior.AllowGet);
        }
    }
}
